<script setup lang="ts">
import { shallowReactive } from 'vue'
import DictionaryPicker from '@/components/DictionaryPicker/DictionaryPicker.vue'

defineEmits<{
  (e: 'search'): void
}>()

const query = shallowReactive({
  type: '',
})

defineExpose({
  query,
})
</script>

<template>
  <ElForm inline :model="query">
    <ElFormItem label="告警类型">
      <DictionaryPicker v-model="query.type" code="GAO_JING_LEI_XING" />
    </ElFormItem>
    <ElFormItem>
      <SearchButton @click="$emit('search')" />
    </ElFormItem>
  </ElForm>
</template>
